
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"  %>

<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>意见反馈</title>
    <meta name="viewport" content="initial-scale=1, maximum-scale=1">
    <!-- <link rel="shortcut icon" href="/favicon.ico"> -->
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" href="<%=basePath %>/resources/Public/Vendor/SUI/dist/css/sm.min.css">

    <link rel="stylesheet" href="<%=basePath %>/resources/Public/Vendor/SUI/dist/css/sm.min.css">
    <link rel="stylesheet" href="<%=basePath %>/resources/Public/Vendor/SUI/dist/css/sm-extend.min.css">
    <link rel="stylesheet" type="text/css" href="<%=basePath %>/resources/Public/Vendor/icon/iconfont.css">

    <link rel="stylesheet" href="<%=basePath %>/resources/Public/css/common.css">

</head>
<body>
<div class="page-group">
    <div class="page xgj-suggest" id="xgj-suggest">
        <div class="content ">
            <div class="content-padded">
                <textarea id="message" placeholder="请描述您遇到的问题和意见，您的意见会让我们为您提供更好的服务哦"></textarea>
            </div>
            <div class="content-block">
                <p><a href="javascript:void(0)" class="button btn-reg-confim btn-sug">提 交</a></p>
            </div>
        </div>
    </div>
</div>
<!--   此处引入 tabar.php -->
<?php include_once("./_footer.php") ?>

<script src='<%=basePath %>/resources/Public/Vendor/SUI/dist/js/zepto.js'></script>
<script type="text/javascript">
    $.config = {
        // 路由功能开关过滤器，返回 false 表示当前点击链接不使用路由
        routerFilter: function($link) {
            // 某个区域的 a 链接不想使用路由功能
            if ($link.is('.disable-router a')) {
                return false;
            }
            return true;
        }
    };
</script>
<script src='<%=basePath %>/resources/Public/Vendor/SUI/dist/js/sm.js'></script>
<script src='<%=basePath %>/resources/Public/Vendor/SUI/dist/js/sm-city-picker.min.js' ></script>
<script src='<%=basePath %>/resources/Public/Vendor/SUI/dist/js/sm-extend.min.js'></script>
<script src='<%=basePath %>/resources/Public/js/common.js'></script>


<!-- / 此处引入 tabar.php -->
<script type="text/javascript">
    $.init();
    $("textarea").focus();
    $(function(){
        $(".btn-sug").on('click',function(){
            var message   = $("#message").val();
            if (message=="") {
                $.toast("不能为空");
                return false;
            }else{
                $.ajax({
                    url: "<%=path%>/wx/msg/addMessage.do",
                    method: 'GET',
                    dataType: 'json',
                    data: {
                        msg: message
                    },
                    success: function(data){
                        $.toast("反馈成功！");
                        window.location.href = '<%=basePath %>wx/user/center.do';
                    }
                });
            }

        })
    });
    /*
     var $ = require("jquery")(window);
     */
    /* function addMessage(){
     alert(123321);
     /!* $.ajax({
     url: "<=path%>/wx/msg/addMessage.do",
     method: 'GET',
     dataType: 'json',
     data: {
     msg: $('#message').val()
     },
     success: function(data){
     window.location.href = '<=basePath %>wx/user/center.do';
     }
     });*!/
     }*/
</script>

</body>
</html>